$width:100px;
$color:#ffe700;

$l:left;
#box{ 
    div{ 
        width:$width;
        background-color: $color;
        margin-#{$l}:10px;
    }
    .#{$l}{ 
        color: red;
    }
}

@for $i from 1 to 5{ 
    .li#{$i}{ 
        background-color: red;
    }
}
 
// 循环得到从1到5 包括5
@for $i from 1 through 5{ 
    .li#{$i}{ 
        background-color: red;
    }
}



$bool:true;
header{ 
    @if $bool{ 
        color: red;
    }@else{ 
        font-size: 12px;
    }
}

$k:2;
@while $k < 10{ 
    .con#{$k}{ 
        font-size:12px;
    }
    $k:$k + 1;
}

@each $key in 100,200,300{ 
    .li#{$key}{ 
        width: $key;
    }
}